var tag=document.getElementById('id');
tag.setAttribute('onclick','');
tag.setAttribute('ondblclick','');
tag.setAttribute('onmousedown','');
tag.setAttribute('onmouseup','');
tag.setAttribute('onmouseover','');
tag.setAttribute('onmousemove','');
tag.setAttribute('onmouseout','');
tag.setAttribute('onkeypress','(event)=>console.log(event.keyCode)');
tag.setAttribute('onkeydown','(event)=>console.log(event.keyCode)');
tag.setAttribute('onkeyup','(event)=>console.log(event.keyCode)');
tag.setAttribute('onload','');
tag.setAttribute('onunload','');

var text=document.getElementsByTagName('input')[0];
text.setAttribute('onfocus','');
text.setAttribute('onblur','');
text.setAttribute('onselect','');
text.setAttribute('onchange','');
text.setAttribute('onsubmit','');
text.setAttribute('onreset','');

tag.setAttribute('onclick','console.log(this)');
tag.onclick=null;
tag.addEventListener('click',()=>console.log(this));
tag.removeEventListener('click',()=>console.log(this,event));
window.addEventListener('resize',()=>{
	console.log('resize');
	event.stopPropagation();
	event.stopImmediatePropagation();
	event.preventDefault();
},true);
var parent=tag.parentElement;
function display(event){
	console.log(`Catch: ${event.target.nodeName}`);
	console.log(`Happen: ${event.currentTarget.nodeName}`);
}
parent.addEventListener('click',display);
